package test3;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.net.Socket;

public class SocketServer extends Thread {
	
	public SocketServer(Socket socket) {
		this.socket = socket;
	}
	
 
	 public void run() {
		
		String output = "";
		
		
		BufferedReader bfr;
		try {
			bfr = new BufferedReader(new InputStreamReader(socket.getInputStream()));
		
		
		 
		PrintWriter pw = new PrintWriter(socket.getOutputStream());
		
		String line = null;
		
		line = bfr.readLine();
		
			output = "server send===";
			
			pw.println(output);
			
			pw.flush();
			
			bfr.close();
			pw.close();
			socket.close();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		
	}
	private Socket socket ;
	
	

}
